<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="/js/vue.js"></script>
</head>
<body>
    <div id="app">
        <input type="text" v-model="message" value="初识Vue.js"/>
        <!-- .lazy修饰符   v-model在每次input事件触发后将输入框的值与数据进行同步，此时添加.lazy修饰符,从而转为在change事件之后进行同步-->
        <input v-model.lazy="msg">
        <!-- .number修饰符  将用户输入值转换为数值类型 -->
        <input v-model.number="age" type="number">
        <!-- .trim修饰符  自动过滤用户首尾空白字符 -->
        <input v-model.trim="msg">
    </div>
    <script>
        var vm = new Vue({
            el:'#app',
            data:{
                message:'Vue.js从入门到精通'
            }
        });
        

    </script>
</body>
</html>